package cn.hdustea.shopNavigation.net.service

import cn.hdustea.shopNavigation.entity.UserEntity
import io.reactivex.Observable
import retrofit2.http.Field
import retrofit2.http.FormUrlEncoded
import retrofit2.http.POST

interface AccountService {
    @FormUrlEncoded
    @POST("/login")
    fun login(@Field("username") username: String, @Field("password") password: String):
            Observable<com.hdustea.base.entity.Result<UserEntity>>

    @FormUrlEncoded
    @POST("/register")
    fun register(
            @Field("username") username: String,
            @Field("password") password: String,
            @Field("phone") phone: String,
    ): Observable<com.hdustea.base.entity.Result<String>>
}